﻿using System;
using Pay.TO;

namespace Pay.Data {
	/// <summary>
	/// 平台账单明细表：mc_BillDetail
	/// </summary>
	public class PlatBillDetail {
		public PlatBillDetail() {
		}
		/// <summary>
		/// 明细id
		/// </summary>
		public long Id { get; set; }
		/// <summary>
		/// 账单id
		/// </summary>
		public long PlatBillId { get; set; }
		/// <summary>
		/// 可能订单id,退款id,提现id
		/// </summary>
		public long? ObjectId { get; set; }
		/// <summary>
		/// 账单类型：1交易，2退款，3提现，4手续费，5结算费，6补粘
		/// </summary>
		public BillType BillType { get; set; }
		/// <summary>
		/// 收支金额
		/// </summary>
		public decimal Amount { get; set; }
		/// <summary>
		/// 余额
		/// </summary>
		public decimal Balance { get; set; }
		/// <summary>
		/// 状态：1进行中(收入待确认、退款中、提现申请)，2完成，3失败
		/// <para>收款：1待发货，2完成；</para>
		/// <para>提现：1提现中，2完成</para>
		/// <para>退款：1待退款，2完成，3失败</para>
		/// </summary>
		public BillStatus Status { get; set; }
		/// <summary>
		/// 增加时间
		/// </summary>
		public long CreateTime { get; set; }

		/// <summary>
		/// 支付信息id
		/// </summary>
		public long PayId { get; set; }
		/// <summary>
		/// 支付信息表：mc_PayInfo
		/// </summary>
		public virtual PayInfo PayInfo { get; set; }

		/// <summary>
		/// 平台账单
		/// </summary>
		public virtual PlatBill PlatBill { get; set; }
	}
}
